package com.woniuxy.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.woniuxy.domain.Permission;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author XXX
 * @since 2021-05-12
 */
public interface PermissionService extends IService<Permission> {
    /**
     *@Author 王昊波
     *@Description 根据用户id查询对应的权限
     *@Param [userId]
     *@return java.util.List<com.woniuxy.domain.Permission>
     */
    public List<Permission> selectPermissionByUserId(int userId) throws Exception;
    /**
     *@Author 王昊波
     *@Description 根据角色id查询对应的权限
     *@Param [roleId]
     *@return java.util.List<com.woniuxy.domain.Permission>
     */
    public List<Permission> selectPermissionByRoleId(int roleId) throws Exception;
    /**
     *@Author 王昊波
     *@Description 查询所有的权限
     *@Param []
     *@return java.util.List<com.woniuxy.domain.Permission>
     */
    public List<Permission> selectAllPermission() throws Exception;
    /**
     *@Author 王昊波
     *@Description 根据用户ID查询所有权限，不需要映射
     *@Param [userId]
     *@return java.util.List<com.woniuxy.domain.Permission>
     */
    public List<Permission> selectPermissionByUserIdNo(int userId) throws Exception;
}
